package com.minimalist.common.entity.lindi.po;

import com.minimalist.common.config.mybatis.InsertFullColumnHandler;
import com.minimalist.common.config.mybatis.UpdateFullColumnHandler;
import com.minimalist.common.config.mybatis.bo.BaseEntity;
import com.mybatisflex.annotation.Table;


import java.io.Serial;
import java.io.Serializable;

/**
 * 林地指标交易平台_活动内容表 实体类。
 *
 * @author 11987
 * @since 2025-06-12
 */
@Table(value = "LINDI_ACTIVITY", onInsert = InsertFullColumnHandler.class, onUpdate = UpdateFullColumnHandler.class)
public class LindiActivity extends BaseEntity implements Serializable{

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 活动ID
     */
    private Long activityId;

    /**
     * 活动标题
     */
    private String activityTitle;

    /**
     * 活动内容
     */
    private String activityContent;

    /**
     * 状态  0禁用 1正常
     */
    private Integer status;

    /**
     * 置顶  0否 1是
     */
    private Boolean activityTop;

    /**
     * 排序
     */
    private Integer activitySort;

    public LindiActivity() {
    }

    public LindiActivity(Long activityId, String activityTitle, String activityContent, Integer status, Boolean activityTop, Integer activitySort) {
        this.activityId = activityId;
        this.activityTitle = activityTitle;
        this.activityContent = activityContent;
        this.status = status;
        this.activityTop = activityTop;
        this.activitySort = activitySort;
    }

    public Long getActivityId() {
        return activityId;
    }

    public void setActivityId(Long activityId) {
        this.activityId = activityId;
    }

    public String getActivityTitle() {
        return activityTitle;
    }

    public void setActivityTitle(String activityTitle) {
        this.activityTitle = activityTitle;
    }

    public String getActivityContent() {
        return activityContent;
    }

    public void setActivityContent(String activityContent) {
        this.activityContent = activityContent;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public Boolean getActivityTop() {
        return activityTop;
    }

    public void setActivityTop(Boolean activityTop) {
        this.activityTop = activityTop;
    }

    public Integer getActivitySort() {
        return activitySort;
    }

    public void setActivitySort(Integer activitySort) {
        this.activitySort = activitySort;
    }

    public static LindiActivityBuilder builder() {
        return new LindiActivityBuilder();
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        if (!super.equals(o)) return false;
        LindiActivity that = (LindiActivity) o;
        return java.util.Objects.equals(activityId, that.activityId) &&
               java.util.Objects.equals(activityTitle, that.activityTitle) &&
               java.util.Objects.equals(activityContent, that.activityContent) &&
               java.util.Objects.equals(status, that.status) &&
               java.util.Objects.equals(activityTop, that.activityTop) &&
               java.util.Objects.equals(activitySort, that.activitySort);
    }

    @Override
    public int hashCode() {
        return java.util.Objects.hash(super.hashCode(), activityId, activityTitle, activityContent, status, activityTop, activitySort);
    }

    @Override
    public String toString() {
        return "LindiActivity{" +
                "activityId=" + activityId +
                ", activityTitle='" + activityTitle + '\'' +
                ", activityContent='" + activityContent + '\'' +
                ", status=" + status +
                ", activityTop=" + activityTop +
                ", activitySort=" + activitySort +
                '}';
    }

    public static class LindiActivityBuilder {
        private Long activityId;
        private String activityTitle;
        private String activityContent;
        private Integer status;
        private Boolean activityTop;
        private Integer activitySort;

        public LindiActivityBuilder activityId(Long activityId) {
            this.activityId = activityId;
            return this;
        }

        public LindiActivityBuilder activityTitle(String activityTitle) {
            this.activityTitle = activityTitle;
            return this;
        }

        public LindiActivityBuilder activityContent(String activityContent) {
            this.activityContent = activityContent;
            return this;
        }

        public LindiActivityBuilder status(Integer status) {
            this.status = status;
            return this;
        }

        public LindiActivityBuilder activityTop(Boolean activityTop) {
            this.activityTop = activityTop;
            return this;
        }

        public LindiActivityBuilder activitySort(Integer activitySort) {
            this.activitySort = activitySort;
            return this;
        }

        public LindiActivity build() {
            return new LindiActivity(activityId, activityTitle, activityContent, status, activityTop, activitySort);
        }
    }

}
